package com.woniuxy.conmon.enums;


import io.swagger.annotations.Api;

@Api("系统状态码")
public enum SystemCode implements ResultCode {
    // 定义枚举对象
    SUCCESS(200, "操作成功"),
    FAIL(500, "操作失败"),

    LOGOUT(200, "退出成功"),
    ADDCATEGORY_SUCCESS(200,"新增品类成功"),
    DELETECATEGORY_SUCCESS(200,"删除品类成功"),
    REMOVECATEGORY_SUCCESS(200,"下架品类成功"),
    REMOVEGOODS_SUCCESS(200,"下架商品成功"),
    UPGOODS_SUCCESS(200,"上架商品成功"),
    UPDATEGOODS_SUCCESS(200,"商品修改成功"),
    DELETEGOODS_SUCCESS(200,"删除商品成功"),
    REMOVEGOODS_FAILURE(501,"商品下架失败，存在未上架商品"),
    UPGOODS_FAILURE(502,"商品上架失败，存在已上架或未通过商品"),
    UPDATECATEGORY_SUCCESS(200,"修改品类成功"),
    ADDSHIPPINGTEMPLATE_SUCCESS(200,"运费模板新增成功"),
    CLOSEORDER_SUCCESS(200,"关闭订单成功"),
    MERGEORDERS_SUCCESS(200,"订单合并成功"),

    INVENTORYUPDATE_SUCCESS(200,"修改库存成功"),

    SUCCESS_SEND(200, "发送验证码成功"),
    EMAIL_SEND_SUCCESS(200, "邮件发送成功"),
    DELETESHIPPING_SUCCESS(200,"模板删除成功"),
    DELETESERVICE_SUCCESS(200,"删除申请成功"),
    OUTPUTEXCEL_SUCCESS(200,"打印订单成功"),
    PUBLISH_SUCCESS(200,"上线成功"),
    OFF_SHELVE_SUCCESS(200,"下架成功"),
    STICKY_SUCCESS(200,"已置顶"),
    PASS_SUCCESS(200,"已通过"),
    REVIEW_FAILED(503,"审核未通过"),
    CANCEL_STICKY_SUCCESS(200,"已取消置顶"),
    SUBMIT_SUCCESS(200,"已提交审核，请耐心等待"),
    WITHDRAW_SUCCESS(200,"已撤回"),
    ADDGOODS_SUCCESS(200,"新增商品成功");


    private Integer code;
    private String message;


    SystemCode(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    /**
     * 获取状态码
     */
    @Override
    public Integer getCode() {
        return this.code;
    }

    /**
     * 获取状态信息
     */
    @Override
    public String getMessage() {
        return this.message;
    }

}
